import Vue from 'vue'
import Router from 'vue-router'
import transit from '../components/transit'
import home from '../components/home'
import inhand from '../components/inhand'
import finish from '../components/finish'
import statistics from '../components/statistics'
import dwtj from '../components/dwtj'
import disease from '../components/disease'

Vue.use(Router)

export default new Router({
  mode: "history",
  linkActiveClass: 'link-active',
  routes: [
    {path: '/', redirect: {name: 'transit'}},
    {
      path: "/transit",
      name: "transit",
      component: transit
    },
    {
      path: "/home",
      name: "home",
      component: home,
      redirect: '/rescue/inhand',
      children: [
        {name: 'inhand', path: '/rescue/inhand', component: inhand},
        {name: 'finish', path: '/rescue/finish', component: finish},
        {name: 'statistics', path: '/statistics', component: statistics},
        {name: 'dwtj', path: '/dwtj', component: dwtj},
        {name: 'disease', path: '/disease', component: disease},
      ]
    }
  ]
})
